package com.demo.controller.from;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.time.LocalDateTime;
import java.util.List;

@Data
@ApiModel("场次详情")
public class ostentationAddFrom {

    //开始时间
    @NotNull
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern="yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("开始时间 yyyy-MM-dd HH:mm:ss")
    private LocalDateTime screeningTime;
    //结束
    @NotNull
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern="yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("结束时间 yyyy-MM-dd HH:mm:ss")
    private LocalDateTime endTime;

    //票价
    @NotNull
    @Min(0)
    @ApiModelProperty("票价")
    private String price;

    //座位
    @NotNull
    @Size(min = 1,max = 1000)
    private List<SeatingOstFrom> seatingList;
}
